package com.nwpu.server.admin.service.impl;

import com.nwpu.server.admin.dao.MethodDao;
import com.nwpu.server.admin.entity.MethodEntity;
import com.nwpu.server.admin.service.MethodService;
import com.nwpu.server.common.response.PageUtils;
import com.nwpu.server.common.response.Query;
import org.springframework.stereotype.Service;
import java.util.Map;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;


@Service("methodService")
public class MethodServiceImpl extends ServiceImpl<MethodDao, MethodEntity> implements MethodService {

    @Override
    public PageUtils queryPage(Map<String, Object> params) {
        IPage<MethodEntity> page = this.page(
                new Query<MethodEntity>().getPage(params),
                new QueryWrapper<MethodEntity>()
        );

        return new PageUtils(page);
    }

}